package de.ifi.lmu.snitzelhunt.util.basics;

import java.util.ArrayList;

/**
 * A simple Container Object for an ArrayList<Ranking> necessary for json
 * handling with the Google gson Library
 * 
 * @author jaschkowitz
 * 
 */
public class RankingContainer {
	ArrayList<Ranking> ranking;

	public RankingContainer() {
	}

	public ArrayList<Ranking> getRanking() {
		return ranking;
	}

	public void setRanking(ArrayList<Ranking> ranking) {
		this.ranking = ranking;
	}

	public String toString() {
		StringBuilder sbuild = new StringBuilder();
		sbuild.append(getClass().getName() + " \n");
		if (getRanking() != null) {
			sbuild.append("Rankings: " + getRanking().size() + "\n");
			for (Ranking i : getRanking()) {
				sbuild.append(i + " \n");
			}
		} else
			sbuild.append("Ranking null");
		return sbuild.toString();
	}

}
